package com.ozo.boot.common.base.model;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serial;
import java.io.Serializable;
import java.util.Set;

/**
 * 当前用户
 *
 * @author qiangesoft
 * @date 2024-07-11
 */
@Schema(description = "登录用户")
@Data
@NoArgsConstructor
public class LoginUser implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 用户id
     */
    @Schema(description = "用户id")
    private Long userId;

    /**
     * 用户名
     */
    @Schema(description = "用户名")
    private String username;

    /**
     * 用户昵称
     */
    @Schema(description = "用户昵称")
    private String nickname;

    /**
     * 手机号
     */
    @Schema(description = "手机号")
    private String mobile;

    /**
     * 用户姓名
     */
    @Schema(description = "用户姓名")
    private String realName;

    /**
     * 性别：1-男 0-女
     */
    @Schema(description = "性别：1-男 0-女")
    private String gender;

    /**
     * 部门id
     */
    @Schema(description = "部门id")
    private Long deptId;

    /**
     * 部门名称
     */
    @Schema(description = "部门名称")
    private String deptName;

    /**
     * 访问令牌
     */
    @Schema(description = "访问令牌")
    private String accessToken;

    /**
     * 头像
     */
    @Schema(description = "头像")
    private String avatar;

    /**
     * 有效期
     */
    @Schema(description = "有效期")
    private Long expires;

    /**
     * 刷新访问令牌
     */
    @Schema(description = "刷新访问令牌")
    private String refreshToken;

    /**
     * 记住我
     */
    @Schema(description = "记住我")
    private Boolean rememberMe;

    /**
     * 菜单权限
     */
    @Schema(description = "菜单权限")
    private Set<String> permissions;

    /**
     * 角色权限
     */
    @Schema(description = "角色权限")
    private Set<String> roles;

}
